---
title: "Encryption Fetch API (COPY)"
method: POST
path: "/?vault-fetch (COPY)"
---

# Encryption Fetch API (COPY)

`POST /?vault-fetch (COPY)`

To fetch the details, pass either **Transaction ID** alone or **Vault ID along with Payment ID** to retrieve the Encrypted PAN, Encrypted Session Key, and Key Label.

## Request body

- object
  - `appid` string, required — Merchant APP ID (Alphanumeric - Length of 32 chars and special chars $@%#)
  - `appkey` string, required — Merchant APP KEY (Alphanumeric - Length of 32 chars and special chars $@%#)
  - `epi` string, required — EPI is an end point identifier, Identify the device on valor infrastructure, it's a 10 digit number starts with 2
  - `txn_type` string, required — Transaction type should be set as 'fetchEncryptedInfo'
  - `txn_id` string — A unique response transaction ID from the response of a sale transaction (Numeric - Length of 20 chars)
  - `CustomerProfileID` string — Vault customer profile ID
  - `PaymentProfileID` string — Vault customer payment profile ID

## Response `200`

200

- object
  - `error_no` string
  - `error_code` string
  - `data` object
    - `cardholder_name` string
    - `masked_pan` string
    - `token` string
    - `card_type` string
    - `card_brand` string
    - `spx_encrypted_pan` string
    - `spx_iso_key_label` string
    - `spx_iso_session_key` string
    - `customer_name` string

## Other responses

- `400` — 400

---

[API](https://skmtc.net/valorpaytech/apis/ecommerce-api.md) · [All operations](https://skmtc.net/valorpaytech/apis/ecommerce-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/valorpaytech/ecommerce-api/revisions/c6468b606325/schema)
